package com.springboot.onlinemusicserver.controller;

import com.springboot.onlinemusicserver.service.MusicService;
import com.springboot.onlinemusicserver.utils.common.Result;
import jakarta.annotation.Resource;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * Created with IntelliJ IDEA.
 * Description :
 * User: jiume
 * Date: 2025-05-23
 * Time: 10:04
 */
@RestController
public class TestController {

    @Resource
    private MusicService musicService;

    @RequestMapping("/test01")
    public ResponseEntity<byte[]> test01() {
        String path = "zhangsan/陈势安 - 天后.mp3";
        return musicService.getMusic(path);
    }
}
